package com.niiwoo.civet.mobile.vo.common;

import java.math.BigDecimal;

import io.swagger.annotations.ApiModel;
import io.swagger.annotations.ApiModelProperty;
import lombok.Getter;
import lombok.Setter;

/**
 * 联动配置
 * 
 * @author liuchun
 *
 *         2018年8月9日
 */
@Getter
@Setter
@ApiModel("自动投资/批量投资联动")
public class LinkageConfig {

	@ApiModelProperty("标的类型")
	private Product productType;
	@ApiModelProperty("期限")
	private Period periodType;
	@ApiModelProperty("还款方式")
	private Repayment repaymentType;
	@ApiModelProperty("利率")
	private Rate rateType;

	@Getter
	@Setter
	@ApiModel("产品类型")
	public static class Product {
		@ApiModelProperty("产品名称")
		private String name;
		@ApiModelProperty("产品值")
		private Byte value;

	}

	@Getter
	@Setter
	@ApiModel("期数")
	public static class Period {
		@ApiModelProperty("期数名称")
		private String name;
		@ApiModelProperty("期数")
		private Integer deadline;
		@ApiModelProperty("期数单位(1:月，2:天)")
		private Byte deadlineUnit;

	}

	@Getter
	@Setter
	@ApiModel("期数值信息")
	public static class PeriodValue {
		@ApiModelProperty("期数")
		private Integer deadline;
		@ApiModelProperty("期数单位(1:月，2:天)")
		private Byte deadlineUnit;

	}

	@Getter
	@Setter
	@ApiModel("还款方式")
	public static class Repayment {
		@ApiModelProperty("还款方式名称")
		private String name;
		@ApiModelProperty("还款方式值")
		private Byte value;

	}

	@Getter
	@Setter
	@ApiModel("利率")
	public static class Rate {
		@ApiModelProperty("利率名称")
		private String name;
		@ApiModelProperty("利率值")
		private BigDecimal value;

	}

}
